import noPermissionImg from "@/assets/common/images/noPermission.png";
import { Layout } from "antd";
import "./index.less";

const NoPermission = (props: { noMenu?: boolean; hidden?: boolean }) => {
  const { noMenu, hidden } = props;

  return (
    <Layout className="size100 no-permission-page" style={{ opacity: hidden ? 0 : 1 }}>
      <img src={noPermissionImg} className="no-permission-img" />
      {noMenu && <span className="tips">您无系统功能权限，请联系管理员!</span>}
      {!noMenu && <span className="tips">您无该功能权限，请联系管理员!</span>}
    </Layout>
  );
};

export default NoPermission;
